<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <title>Query Activities</title>
    <!-- 添加你的样式或其他头部信息 -->
    <style>
        /* 添加你的CSS样式以美化界面 */
        body {
            font-family: Arial, sans-serif;
            background-color: #f4f4f4;
            text-align: center;
            margin-top: 20px;
        }

        h2 {
            color: #333;
        }

        table {
            width: 80%;
            margin: 20px auto;
            border-collapse: collapse;
            background-color: #fff;
            box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
        }

        th, td {
            padding: 12px;
            border: 1px solid #ccc;
            text-align: left;
        }

        th {
            background-color: #4caf50;
            color: #fff;
        }

        tr:nth-child(even) {
            background-color: #f9f9f9;
        }

        /* 添加其他样式 */
        .add-button {
            display: inline-block;
            background-color: #4caf50;
            color: #fff;
            padding: 10px 20px;
            text-decoration: none;
            border-radius: 5px;
            margin-top: 20px;
        }
    </style>
</head>
<body>
<h2>Activities List</h2>
<!-- 添加活动列表表格 -->
<table border="1">
    <thead>
    <tr>
        <th>ID</th>
        <th>Name</th>
        <th>Category</th>
        <th>Creator</th>
        <th>Status</th>
    </tr>
    </thead>
    <tbody>
    <tr th:each="activity : ${activities}">
        <td th:text="${activity.id}"></td>
        <td th:text="${activity.name}"></td>
        <td th:text="${activity.category}"></td>
        <td th:text="${activity.creator}"></td>
        <td th:text="${activity.status}"></td>
        <!-- 添加其他表格单元格信息 -->
    </tr>
    </tbody>
</table>


<a th:href="@{/activities/add-activity}" class="add-button">Add Activity</a>



</body>
</html>
